package com.xoms.admin.service;

import com.xoms.admin.controller.res.bean.RPurchaseBean;
import com.xoms.admin.controller.res.bean.RPurchaseInfoBean;
import com.xoms.admin.model.AccountBean;
import com.xoms.admin.service.res.PageResult;

/**
 * 采购单
 * @author admin
 *
 */
public interface PurchaseService {

	/**
	 *  获取采购单列表
	 * @param account
	 * @param key
	 * @param page
	 * @param pageSize
	 * @param startTime
	 * @param endTime
	 * @param storeId
	 * @return
	 */
	PageResult<RPurchaseBean> getPurchases(AccountBean account, String key, int page, int pageSize, String startTime,
			String endTime, String storeId);
	
	/**
	 * 获取采购单详情列表
	 * @param account
	 * @param key
	 * @param page
	 * @param pageSize
	 * @param purchaseId
	 * @param paging 
	 * @return
	 */
	PageResult<RPurchaseInfoBean> getPurchaseDetails(AccountBean account, String key, int page, int pageSize,
			String purchaseId, int paging);
	
	/**
	 * 新建采购单
	 * @param account
	 * @param pid
	 * @param storeId
	 * @param batch
	 * @param remark
	 * @param totalCost
	 * @param details
	 * @param providerId 
	 * @param isSubmit 
	 * @return
	 */
	RPurchaseBean edit(AccountBean account, String pid, String storeId, String batch, String remark,
			Double totalCost, String details, String providerId, int isSubmit);
	
	/**
	 * 删除采购单
	 * @param account
	 * @param purchaseId
	 * @return
	 */
	boolean del(AccountBean account, String purchaseId);
	
	/**
	 * 提交审核
	 * @param account
	 * @param purchaseId
	 * @return
	 */
	boolean submitPurchase(AccountBean account, String purchaseId);
	

}
